#include <iostream>

using namespace std;

class CBase {
	public:
		CBase () {
            cout << "ENTER : CBase :: CBase" << endl;
            cout << "EXIT  : CBase :: CBase" << endl;
		}
		virtual ~CBase () {
            cout << "ENTER : CBase :: ~CBase" << endl;
            cout << "EXIT  : CBase :: ~CBase" << endl;
		}
};

class CDerived : public CBase {
	public:
		CDerived () {
            cout << "ENTER : CDerived :: CDerived" << endl;
            cout << "EXIT  : CDerived :: CDerived" << endl;
		}
		~CDerived () {
            cout << "ENTER : CDerived :: ~CDerived" << endl;
            cout << "EXIT  : CDerived :: ~CDerived" << endl;
		}
};

int main () {
	CBase *bp = new CDerived;
    delete bp;
	return 0;
}
